//用户管理模块相关类型定义
export interface ResponseData {
  code: number
  message: string
  ok: boolean
}
//代表一个用户账号信息的类型
export interface User {
  id?: number | string
  createTime?: string
  updateTime?: string
  username: string
  password: string
  name: string
  phone?: null
  roleName?: string
}
export type Records = User[]
//获取全部用户接口返回数据类型
export interface UserResponseData extends ResponseData {
  data: {
    total: number
    size: number
    current: number
    pages: number
    records: Records
  }
}

//用户职位类型
export interface Role {
  id?: number | string
  createTime?: string
  updateTime?: string
  roleName: string
  remark?: null
}
export type AllRole = Role[]
//获取用户职位接口返回数据类型
export interface RoleResponseData extends ResponseData {
  data: {
    assignRoles: AllRole
    allRolesList: AllRole
  }
}

//给用户分配职位接口携带的参数类型
export interface SetRoleData {
  roleIdList: number[]
  userId: number
}
